----------------------------------------------------------------------------------------------------------------------------------------------------------------------
      name:  <unnamed>
       log:  C:\Users\LA\Dropbox\WORK\RESEARCH\PROJECTS\AMNESTY\Text\P1.4 ISQ submission\proofs\data files\Daniels_ISQ_log.log
  log type:  text
 opened on:  10 Jan 2021, 17:40:33

. do "C:\Users\LA\AppData\Local\Temp\STD00000000.tmp"

. /**************************************************************************
> ** 
> ** File name   : Daniels_ISQ_replication.do
> ** Date        : 1 January 2020
> ** Author      : Lesley-Ann Daniels (ldaniels@ibei.org)
> ** Purpose     : Replicates main results of "Stick then carrot: When do governments give amnesty during civil war? (International Studies Quarterly)"
> ** Requires    : Daniels_ISQ_data.dta, eststo.ado, estout.ado
> ** Output      : Daniels_ISQ_replication.log
> **
> **************************************************************************/
. 
. ** Table 1
. 
. sort dyadid year

. tsset dyadid year
       panel variable:  dyadid (unbalanced)
        time variable:  year, 1990 to 2011, but with gaps
                delta:  1 unit

. 
. eststo, title("Model 1"): quietly logit amnesty  lnrebdeathl lngovdeathl   v2x_polyarchyl lgdppcMadl  meanlnrebdeathl meanlngovdeathl  meanv2x_polyarchyl  durdyad d
> urdyad2 durdyad3 meandurdyad    meanlgdppcMadl  if ampa !=1, cluster (dyadid)
(est1 stored)

. eststo, title("Model 2"): quietly logit amnesty  lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl meanlngovdeathl  meanrebstrcgs mea
> nv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  if ampa !=1, cluster (dyadid)
(est2 stored)

. eststo, title("Model 3"): quietly logit amnesty  lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl meanlngovdeathl  meanrebstrcgs mea
> nv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc if ampa !=1, cluster (dyadid)
(est3 stored)

. estout, cells(b(star  fmt(%9.3f)) se(par fmt(2))) label varlabels(_cons Constant) title(Effects of amnesty) stats(N ll aic bic, label(Observations Pseudologlikeliho
> od AIC BIC)) starlevels(* 0.10 ** 0.05 *** 0.01)

Effects of amnesty
--------------------------------------------------------------------
                          Model 1         Model 2         Model 3   
                             b/se            b/se            b/se   
--------------------------------------------------------------------
amnesty                                                             
log lag rebel deaths        0.343***        0.343***        0.336***
                           (0.11)          (0.11)          (0.11)   
log lag state deaths       -0.148*         -0.190**        -0.195*  
                           (0.09)          (0.08)          (0.11)   
lag regime                  2.116           2.013           6.217***
                           (1.85)          (2.02)          (1.97)   
GDPpc log lag Madd~n       -0.490          -0.785          -0.994   
                           (0.66)          (0.65)          (0.99)   
meanlnrebdeathl            -0.401***       -0.391***       -0.382***
                           (0.15)          (0.15)          (0.15)   
meanlngovdeathl             0.594***        0.592***        0.360** 
                           (0.17)          (0.17)          (0.17)   
meanv2x_polyarchyl         -2.769          -2.511          -6.328***
                           (1.88)          (2.06)          (2.10)   
duration dyad              -0.033           0.009          -0.311   
                           (0.16)          (0.17)          (0.19)   
duration dyad squa~d        0.002          -0.001           0.004   
                           (0.01)          (0.01)          (0.01)   
duration dyad cubed        -0.000           0.000          -0.000   
                           (0.00)          (0.00)          (0.00)   
meandurdyad                 0.041           0.052           0.213***
                           (0.06)          (0.06)          (0.08)   
meanlgdppcMadl              0.415           0.696           0.735   
                           (0.71)          (0.70)          (1.04)   
lag rebel str CGS                          -1.213**        -1.524** 
                                           (0.59)          (0.69)   
meanrebstrcgs                               1.249***        1.354** 
                                           (0.48)          (0.55)   
past dyad amnesty                                           0.593** 
                                                           (0.28)   
post ICC                                                    1.334***
                                                           (0.47)   
meanpastdyadam                                              0.006   
                                                           (0.34)   
meanpicc                                                   -1.435** 
                                                           (0.69)   
Constant                   -2.767**        -2.920*         -0.317   
                           (1.39)          (1.60)          (1.60)   
--------------------------------------------------------------------
Observations              646.000         618.000         618.000   
Pseudologlikelihood      -238.054        -223.018        -197.512   
AIC                       502.109         476.036         433.025   
BIC                       560.229         542.433         517.128   
--------------------------------------------------------------------

. eststo clear

. 
. 
end of do-file

. do "C:\Users\LA\AppData\Local\Temp\STD00000000.tmp"

. ** Figure 1
. 
. quietly logit amnesty  lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl meanlngovdeathl  meanrebstrcgs meanv2x_polyarchyl  durdyad d
> urdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc if ampa !=1, cluster (dyadid)

. margins, at(lnrebdeathl=(0 1.61 3.79 5.97 8.873)) 

Predictive margins                              Number of obs     =        618
Model VCE    : Robust

Expression   : Pr(amnesty), predict()

1._at        : lnrebdeathl     =           0

2._at        : lnrebdeathl     =        1.61

3._at        : lnrebdeathl     =        3.79

4._at        : lnrebdeathl     =        5.97

5._at        : lnrebdeathl     =       8.873

------------------------------------------------------------------------------
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
         _at |
          1  |   .0443533   .0194671     2.28   0.023     .0061985    .0825081
          2  |     .06966   .0190412     3.66   0.000       .03234      .10698
          3  |   .1234388    .013053     9.46   0.000     .0978555    .1490221
          4  |   .2065853   .0301902     6.84   0.000     .1474136    .2657569
          5  |   .3654522   .0961318     3.80   0.000     .1770374     .553867
------------------------------------------------------------------------------

. marginsplot, ///
>   title("")  ///
>   ytitle("Predicted probability of amnesty") ///
>   xtitle("Level of rebel deaths, log and lag") ///
>   xlabel(0 "0" 1.61 "- 1 sd" 3.79 "mean" 5.97 "+ 1 sd" 8.873 "max") ///
>   plot1(color(black)) ///
>   graphregion(color(white)) ///
>   legend(off)

  Variables that uniquely identify margins: lnrebdeathl

.   
. 
end of do-file

. do "C:\Users\LA\AppData\Local\Temp\STD00000000.tmp"

. ** Robustness checks
. 
. *Table A3 Tests on model 3
. *with ukpo
. eststo, title("Model A3.1"): quietly logit amnesty unpko meanunpko lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl meanlngovdeathl 
>  meanrebstrcgs meanv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc if ampa !=1, cluster (dyadid)
(est1 stored)

. *with democracy breakdowns (Boix et al)
. eststo, title("Model A3.2"): quietly logit amnesty democracy_breakdowns  meandemocracy_breakdowns lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  m
> eanlnrebdeathl meanlngovdeathl  meanrebstrcgs meanv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc i
> f ampa !=1, cluster (dyadid)
(est2 stored)

. *with resources (Lujala)
. eststo, title("Model A3.3"): quietly logit amnesty resource  meanresource lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl meanlngov
> deathl  meanrebstrcgs meanv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc if ampa !=1, cluster (dya
> did)
(est3 stored)

. *with other dyads in conflict
. eststo, title("Model A3.4"): quietly logit amnesty numdyadconfl meannumdyadconfl lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl me
> anlngovdeathl  meanrebstrcgs meanv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc if ampa !=1, clust
> er (dyadid)
(est4 stored)

. *with alternative measure of intensity
. eststo, title("Model A3.5"): quietly logit amnesty intensityl meanintensityl lnrebdeathl    rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl   meanrebstrcgs m
> eanv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc if ampa !=1, cluster (dyadid)
(est5 stored)

. *without FARC
. eststo, title("Model A3.6"): quietly logit amnesty  lnrebdeathl lngovdeathl   rebstrcgs3l v2x_polyarchyl lgdppcMadl  meanlnrebdeathl meanlngovdeathl  meanrebstrcgs 
> meanv2x_polyarchyl  durdyad durdyad2 durdyad3 meandurdyad    meanlgdppcMadl  pastdyadam picc meanpastdyadam meanpicc if ampa !=1 & dyadid !=237, cluster (dyadid)
(est6 stored)

. *as linear probability model
. xtset dyadid year
       panel variable:  dyadid (unbalanced)
        time variable:  year, 1990 to 2011, but with gaps
                delta:  1 unit

. eststo, title("Model A3.7"): quietly xtreg amnesty  lnrebdeathl lngovdeathl rebstrcgs3l v2x_polyarchyl  lgdppcMadl durdyad durdyad2 durdyad3 pastdyadam picc if ampa
>  !=1, fe
(est7 stored)

. eststo, title("Model A3.8"): quietly xtlogit amnesty  lnrebdeathl lngovdeathl rebstrcgs3l v2x_polyarchyl  lgdppcMadl durdyad durdyad2 durdyad3 pastdyadam picc if am
> pa !=1, fe
(est8 stored)

. estout, cells(b(star  fmt(%9.3f)) se(par fmt(2))) label varlabels(_cons Constant) title(Effects of amnesty) stats(N ll aic bic, label(Observations Pseudologlikeliho
> od AIC BIC)) starlevels(* 0.10 ** 0.05 *** 0.01)

Effects of amnesty
----------------------------------------------------------------------------------------------------------------------------------------------------
                       Model A3.1      Model A3.2      Model A3.3      Model A3.4      Model A3.5      Model A3.6      Model A3.7      Model A3.8   
                             b/se            b/se            b/se            b/se            b/se            b/se            b/se            b/se   
----------------------------------------------------------------------------------------------------------------------------------------------------
main                                                                                                                                                
UN peacekeeping            -2.359***                                                                                                                
                           (0.69)                                                                                                                   
meanunpko                   2.002**                                                                                                                 
                           (0.79)                                                                                                                   
log lag rebel deaths        0.324***        0.368***        0.359***        0.329***        0.243***        0.331***        0.039***        0.317** 
                           (0.12)          (0.11)          (0.11)          (0.12)          (0.09)          (0.11)          (0.01)          (0.13)   
log lag state deaths       -0.178          -0.209**        -0.221**        -0.173                          -0.187*         -0.023          -0.194   
                           (0.11)          (0.10)          (0.11)          (0.11)                          (0.11)          (0.01)          (0.15)   
lag rebel str CGS          -1.376**        -2.254***       -1.624**        -1.639**        -1.592**        -1.315**        -0.099          -0.414   
                           (0.65)          (0.68)          (0.66)          (0.65)          (0.69)          (0.66)          (0.11)          (0.85)   
lag regime                  7.132***        5.717**         7.174***        6.365***        6.113***        6.112***        0.484**         3.113   
                           (2.05)          (2.35)          (2.38)          (2.04)          (2.12)          (2.01)          (0.24)          (2.21)   
GDPpc log lag Madd~n       -1.850*         -0.845          -1.265          -0.979          -1.159          -0.834           0.050           0.085   
                           (1.03)          (1.03)          (1.02)          (0.82)          (1.01)          (1.10)          (0.12)          (1.16)   
meanlnrebdeathl            -0.359**        -0.457**        -0.437***       -0.328**        -0.181          -0.392***                                
                           (0.16)          (0.18)          (0.14)          (0.16)          (0.12)          (0.15)                                   
meanlngovdeathl             0.381**         0.402**         0.437***        0.230                           0.346**                                 
                           (0.18)          (0.18)          (0.16)          (0.19)                          (0.17)                                   
meanrebstrcgs               1.175**         1.966***        1.327**         1.348***        1.434***        1.207**                                 
                           (0.54)          (0.52)          (0.53)          (0.51)          (0.54)          (0.52)                                   
meanv2x_polyarchyl         -6.867***       -5.992**        -7.222***       -6.753***       -6.297***       -6.255***                                
                           (2.09)          (2.56)          (2.42)          (2.15)          (2.22)          (2.15)                                   
duration dyad              -0.314          -0.164          -0.339*         -0.372**        -0.338*         -0.265          -0.064***       -0.632***
                           (0.19)          (0.21)          (0.20)          (0.18)          (0.20)          (0.21)          (0.02)          (0.20)   
duration dyad squa~d        0.005          -0.005           0.007           0.007           0.006          -0.004           0.002           0.019   
                           (0.01)          (0.01)          (0.01)          (0.01)          (0.01)          (0.01)          (0.00)          (0.01)   
duration dyad cubed        -0.000           0.000          -0.000          -0.000          -0.000           0.000          -0.000          -0.000   
                           (0.00)          (0.00)          (0.00)          (0.00)          (0.00)          (0.00)          (0.00)          (0.00)   
meandurdyad                 0.176**         0.163*          0.227***        0.213***        0.199***        0.242***                                
                           (0.08)          (0.09)          (0.08)          (0.08)          (0.08)          (0.08)                                   
meanlgdppcMadl              1.524           0.489           0.971           0.650           0.828           0.622                                   
                           (1.06)          (1.09)          (1.09)          (0.88)          (1.03)          (1.16)                                   
past dyad amnesty           0.597**         0.610**         0.581*          0.621***        0.565**         0.585**         0.064***        0.614***
                           (0.28)          (0.30)          (0.34)          (0.23)          (0.29)          (0.29)          (0.02)          (0.22)   
post ICC                    1.569***        1.106**         1.290***        1.320***        1.416***        1.357***        0.146**         1.131*  
                           (0.49)          (0.47)          (0.48)          (0.48)          (0.45)          (0.48)          (0.06)          (0.62)   
meanpastdyadam              0.042           0.040           0.010           0.040           0.122           0.074                                   
                           (0.33)          (0.36)          (0.36)          (0.29)          (0.34)          (0.31)                                   
meanpicc                   -1.412**        -0.110          -1.512**        -1.245*         -1.390**        -1.474**                                 
                           (0.71)          (0.86)          (0.74)          (0.70)          (0.68)          (0.70)                                   
democracy_breakdowns                       -1.750                                                                                                   
                                           (1.40)                                                                                                   
meandemocracy_brea~s                        1.719                                                                                                   
                                           (1.37)                                                                                                   
resources in confl~l                                        0.155                                                                                   
                                                           (0.62)                                                                                   
meanresource                                               -1.035                                                                                   
                                                           (0.67)                                                                                   
number dyads                                                               -0.722**                                                                 
                                                                           (0.33)                                                                   
meannumdyadconfl                                                            0.082                                                                   
                                                                           (0.33)                                                                   
IntensityLevel                                                                              0.376                                                   
                                                                                           (0.46)                                                   
meanintensityl                                                                             -0.632                                                   
                                                                                           (0.67)                                                   
Constant                    0.034           0.275           0.468           1.802           0.758          -0.876          -0.103                   
                           (1.61)          (1.74)          (1.78)          (1.69)          (1.49)          (1.63)          (0.94)                   
----------------------------------------------------------------------------------------------------------------------------------------------------
Observations              618.000         543.000         614.000         618.000         618.000         598.000         618.000         317.000   
Pseudologlikelihood      -192.895        -181.600        -191.563        -191.743        -198.706        -188.071         -96.358        -104.457   
AIC                       427.791         405.201         425.126         425.487         435.412         414.143         214.716         228.913   
BIC                       520.747         495.440         517.946         518.443         519.515         497.621         263.408         266.502   
----------------------------------------------------------------------------------------------------------------------------------------------------

. eststo clear

. 
end of do-file

. log close
      name:  <unnamed>
       log:  C:\Users\LA\Dropbox\WORK\RESEARCH\PROJECTS\AMNESTY\Text\P1.4 ISQ submission\proofs\data files\Daniels_ISQ_log.log
  log type:  text
 closed on:  10 Jan 2021, 17:42:43
----------------------------------------------------------------------------------------------------------------------------------------------------------------------
